export function formatDate(time: Date) {
  const year = time.getFullYear();
  const month = time.getMonth() + 1;
  const date = time.getDate();

  return `${year}-${month >= 10 ? month : "0" + month}-${
    date >= 10 ? date : "0" + date
  }`;
}